load("@rules_cc//cc:defs.bzl", "cc_library")

package(default_visibility = ["//visibility:public"])

cc_library(
    name = "boost.json",
    hdrs = glob(
        [
            "include/**/*.hpp",
            "include/**/*.ipp",
        ],
        exclude = [
            "include/boost/json/detail/**/*.hpp",
            "include/boost/json/detail/**/*.ipp",
            "include/boost/json/impl/error.hpp",
            "include/boost/json/impl/parse.ipp",
            "include/boost/json/impl/string.hpp",
            "include/boost/json/impl/string.ipp",
            "include/boost/json/impl/value.hpp",
            "include/boost/json/impl/value.ipp",
            "include/boost/json/impl/value_ref.hpp",
            "include/boost/json/impl/visit.hpp",
        ],
    ),
    features = [
        "parse_headers",
    ],
    includes = ["include"],
    textual_hdrs = glob([
        "include/boost/json/detail/**/*.hpp",
        "include/boost/json/detail/**/*.ipp",
        "include/boost/json/impl/error.hpp",
        "include/boost/json/impl/parse.ipp",
        "include/boost/json/impl/string.hpp",
        "include/boost/json/impl/string.ipp",
        "include/boost/json/impl/value.hpp",
        "include/boost/json/impl/value.ipp",
        "include/boost/json/impl/value_ref.hpp",
        "include/boost/json/impl/visit.hpp",
    ]),
    deps = [
        "@boost.align",
        "@boost.assert",
        "@boost.config",
        "@boost.container",
        "@boost.container_hash",
        "@boost.core",
        "@boost.describe",
        "@boost.mp11",
        "@boost.system",
        "@boost.throw_exception",
    ],
)
